<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
                    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
                    xmlns:s="clr-namespace:System;assembly=mscorlib"
                    xmlns:sllb="http://schemas.xceed.com/silverlight/xaml/listbox">

   <!-- =================================================================== -->
   <!-- Resources specific to this Theme/ColorScheme                        -->
   <!-- =================================================================== -->

   <LinearGradientBrush x:Key="SilverlightThemeListBoxGroupHearderItemBackgroundBrush"
                        EndPoint="0.5,1"
                        StartPoint="0.5,0">
      <GradientStop Color="#EBEDEF"
                    Offset="1" />

      <GradientStop Color="#FBFBFB"
                    Offset="0" />
   </LinearGradientBrush>

   <SolidColorBrush x:Key="SilverlightThemeLoadingSpinnerShadowBackgroundBrush"
                    Color="#FF616161" />

   <SolidColorBrush x:Key="SilverlightThemeLoadingSpinnerHighlightBackgroundBrush"
                    Color="#BADDE9" />

   <LinearGradientBrush x:Key="SilverlightThemeListBoxDefaultBorderBrush"
                        EndPoint="0.5,1"
                        StartPoint="0.5,0">
      <GradientStop Color="#FFA3AEB9"
                    Offset="0" />
      <GradientStop Color="#FF8399A9"
                    Offset="0.375" />
      <GradientStop Color="#FF718597"
                    Offset="0.375" />
      <GradientStop Color="#FF617584"
                    Offset="1" />
   </LinearGradientBrush>

   <LinearGradientBrush x:Key="SilverlightThemeToolPaneBackgroundBrush"
                        StartPoint="0.5,0"
                        EndPoint="0.5,1">
      <GradientStop Offset="0"
                    Color="#FFE2E2E2" />
      <GradientStop Offset="1"
                    Color="White" />
   </LinearGradientBrush>

   <LinearGradientBrush x:Key="SilverlightThemeGroupNavigationControlButtonPressedBackgroundBrush"
                        StartPoint="0.5,0"
                        EndPoint="0.5,1.04">
      <GradientStop Color="#FFe1ecf6"
                    Offset="0" />

      <GradientStop Color="#FFd5e5f2"
                    Offset="0.3" />

      <GradientStop Color="#FFaecee8"
                    Offset="0.5" />

      <GradientStop Color="#FF75abd8"
                    Offset="1" />
   </LinearGradientBrush>

   <LinearGradientBrush x:Key="SilverlightThemeGroupNavigationControlButtonDefaultBorderBrush"
                        EndPoint="0.5,1"
                        StartPoint="0.5,0">
      <GradientStop Color="#FFCFD0D0"
                    Offset="0" />

      <GradientStop Color="#FFC9CACA"
                    Offset="1" />
   </LinearGradientBrush>

   <LinearGradientBrush x:Key="SilverlightThemeGroupNavigationControlButtonDefaultBackgroundBrush"
                        StartPoint="0.5,0"
                        EndPoint="0.5,1">
      <GradientStop Color="#FFFBFBFB"
                    Offset="0" />

      <GradientStop Color="#FFD6DBDF"
                    Offset="1" />
   </LinearGradientBrush>

   <Style x:Key="SilverlightThemeLicensingStateRichTextBoxStyle"
          TargetType="RichTextBox">
      <Setter Property="HorizontalAlignment"
              Value="Left" />
      <Setter Property="TextWrapping"
              Value="Wrap" />
      <Setter Property="FontSize"
              Value="13.333" />
      <Setter Property="Foreground"
              Value="White" />
      <Setter Property="VerticalAlignment"
              Value="Top" />
      <Setter Property="IsReadOnly"
              Value="True" />
      <Setter Property="IsTabStop"
              Value="False" />
      <Setter Property="CaretBrush"
              Value="Transparent" />

      <Setter Property="Template">
         <Setter.Value>
            <ControlTemplate TargetType="RichTextBox">
               <Border x:Name="ContentElement"
                       Background="Transparent"
                       BorderBrush="Transparent"
                       BorderThickness="0" />
            </ControlTemplate>
         </Setter.Value>
      </Setter>
   </Style>

   <DataTemplate x:Key="SilverlightThemeDataNavigationIcon">
      <Grid HorizontalAlignment="Center"
            VerticalAlignment="Center"
            Margin="0">
         <Grid.Effect>
            <DropShadowEffect BlurRadius="2"
                              ShadowDepth="1"
                              Color="White" />
         </Grid.Effect>
         <Grid.RowDefinitions>
            <RowDefinition Height="4" />
            <RowDefinition Height="3" />
            <RowDefinition Height="4" />
         </Grid.RowDefinitions>
         <Grid.ColumnDefinitions>
            <ColumnDefinition Width="5" />
            <ColumnDefinition Width="7" />
            <ColumnDefinition Width="5" />
         </Grid.ColumnDefinitions>
         <Rectangle StrokeThickness="0"
                    Fill="#FFC1CBD7"
                    Width="5"
                    Height="3"
                    HorizontalAlignment="Center"
                    VerticalAlignment="Center"
                    Margin="0,0,0,1" />
         <Rectangle StrokeThickness="0"
                    Fill="#FFC1CBD7"
                    Width="5"
                    Height="3"
                    Grid.Column="1"
                    HorizontalAlignment="Center"
                    VerticalAlignment="Center"
                    Margin="1,0,1,1" />
         <Rectangle StrokeThickness="0"
                    Fill="#FFC1CBD7"
                    Width="5"
                    Height="3"
                    Margin="0,0,0,1"
                    Grid.Column="2"
                    HorizontalAlignment="Center"
                    VerticalAlignment="Center" />
         <Rectangle StrokeThickness="0"
                    Fill="#FFB1BDCD"
                    Width="5"
                    Height="3"
                    HorizontalAlignment="Center"
                    VerticalAlignment="Center"
                    Grid.Row="1" />
         <Rectangle StrokeThickness="0"
                    Fill="#FFB1BDCD"
                    Width="5"
                    Height="3"
                    Grid.Row="1"
                    Grid.Column="1"
                    HorizontalAlignment="Center"
                    VerticalAlignment="Center"
                    Margin="1,0" />
         <Rectangle StrokeThickness="0"
                    Fill="#FF1A69D6"
                    Width="5"
                    Height="3"
                    Grid.Row="1"
                    Grid.Column="2"
                    HorizontalAlignment="Center"
                    VerticalAlignment="Center"
                    Margin="0" />
         <Rectangle StrokeThickness="0"
                    Fill="#FFA4B2C5"
                    Width="5"
                    Height="3"
                    Grid.Row="2"
                    HorizontalAlignment="Center"
                    VerticalAlignment="Center"
                    Margin="0,1,0,0" />
         <Rectangle StrokeThickness="0"
                    Fill="#FFA4B2C5"
                    Width="5"
                    Height="3"
                    Grid.Row="2"
                    Grid.Column="1"
                    HorizontalAlignment="Center"
                    VerticalAlignment="Center"
                    Margin="1,1,1,0" />
         <Rectangle StrokeThickness="0"
                    Fill="#FFA4B2C5"
                    Width="5"
                    Height="3"
                    HorizontalAlignment="Center"
                    VerticalAlignment="Center"
                    Grid.Row="2"
                    Grid.Column="2"
                    Margin="0,1,0,0" />
      </Grid>
   </DataTemplate>

   <Style x:Key="SilverlightThemeNavigationButtonStyle"
          TargetType="Button">
      <Setter Property="Foreground"
              Value="#6B6A6B" />

      <Setter Property="Height"
              Value="21" />

      <Setter Property="Width"
              Value="29" />

      <Setter Property="Template">
         <Setter.Value>
            <ControlTemplate TargetType="Button">
               <Grid x:Name="grid">
                  <VisualStateManager.VisualStateGroups>
                     <VisualStateGroup x:Name="CommonStates">
                        <VisualStateGroup.Transitions>
                           <VisualTransition GeneratedDuration="00:00:00.200" />

                           <VisualTransition From="MouseOver"
                                             To="Pressed" />
                        </VisualStateGroup.Transitions>

                        <VisualState x:Name="Normal" />

                        <VisualState x:Name="MouseOver">
                           <Storyboard>
                              <DoubleAnimation Duration="00:00:00.000"
                                               To="1"
                                               Storyboard.TargetProperty="(UIElement.Opacity)"
                                               Storyboard.TargetName="Over" />
                           </Storyboard>
                        </VisualState>

                        <VisualState x:Name="Pressed">
                           <Storyboard>
                              <DoubleAnimation Duration="00:00:00.000"
                                               To="1"
                                               Storyboard.TargetProperty="(UIElement.Opacity)"
                                               Storyboard.TargetName="Pressed1" />
                           </Storyboard>
                        </VisualState>

                        <VisualState x:Name="Disabled">
                           <Storyboard>
                              <DoubleAnimation Duration="00:00:00.000"
                                               To="0.5"
                                               Storyboard.TargetProperty="(UIElement.Opacity)"
                                               Storyboard.TargetName="grid" />
                           </Storyboard>
                        </VisualState>
                     </VisualStateGroup>

                     <VisualStateGroup x:Name="FocusStates">
                        <VisualState x:Name="Focused" />

                        <VisualState x:Name="Unfocused" />
                     </VisualStateGroup>
                  </VisualStateManager.VisualStateGroups>

                  <Border x:Name="Background"
                          BorderThickness="{TemplateBinding BorderThickness}"
                          BorderBrush="{StaticResource SilverlightThemeGroupNavigationControlButtonDefaultBorderBrush}"
                          Background="{StaticResource SilverlightThemeGroupNavigationControlButtonDefaultBackgroundBrush}" />

                  <Border x:Name="Over"
                          Opacity="0"
                          BorderThickness="1">
                     <Border.Background>
                        <LinearGradientBrush StartPoint="0.5,0"
                                             EndPoint="0.5,1">
                           <GradientStop Color="#FFfbfcfd"
                                         Offset="0" />

                           <GradientStop Color="#FFeef4f9"
                                         Offset="0.36" />

                           <GradientStop Color="#FFa4c7e5"
                                         Offset="1" />
                        </LinearGradientBrush>
                     </Border.Background>
                  </Border>

                  <Border x:Name="Pressed1"
                          Opacity="0"
                          BorderThickness="1"
                          Background="{StaticResource SilverlightThemeGroupNavigationControlButtonPressedBackgroundBrush}" />

                  <ContentPresenter x:Name="contentPresenter"
                                    Margin="{TemplateBinding Padding}"
                                    ContentTemplate="{TemplateBinding ContentTemplate}"
                                    Content="{TemplateBinding Content}"
                                    HorizontalAlignment="Center"
                                    VerticalAlignment="Center" />
               </Grid>
            </ControlTemplate>
         </Setter.Value>
      </Setter>
   </Style>

   <!--**************************
    * STYLE: ScrollViewer
    ************************** -->
   <Style TargetType="ScrollViewer"
          x:Key="SilverlightThemeScrollViewerStyle">

      <Setter Property="HorizontalContentAlignment"
              Value="Left" />

      <Setter Property="VerticalContentAlignment"
              Value="Top" />

      <Setter Property="VerticalScrollBarVisibility"
              Value="Visible" />

      <Setter Property="BorderBrush"
              Value="Transparent" />

      <Setter Property="BorderThickness"
              Value="0" />

      <Setter Property="Background"
              Value="Transparent" />
   </Style>

   <!--**************************
    * TEMPLATE: ListBox
    ************************** -->
   <ControlTemplate x:Key="SilverlightThemeListBoxTemplate"
                    TargetType="sllb:ListBox">
      <Border BorderBrush="{TemplateBinding BorderBrush}"
              BorderThickness="{TemplateBinding BorderThickness}"
              Background="{TemplateBinding Background}">
         <VisualStateManager.VisualStateGroups>
            <VisualStateGroup x:Name="CommonStates">
               <VisualState x:Name="Normal" />
               <VisualState x:Name="Disabled" />
            </VisualStateGroup>

            <VisualStateGroup x:Name="ResquestStatus">

               <VisualState x:Name="NoPendingRequests" />

               <VisualState x:Name="RequestsPending">
                  <Storyboard>
                     <ObjectAnimationUsingKeyFrames Storyboard.TargetName="loadingIndicator"
                                                    Storyboard.TargetProperty="RequestsPending">
                        <DiscreteObjectKeyFrame KeyTime="00:00:00.0">
                           <DiscreteObjectKeyFrame.Value>
                              <s:Boolean>
                                 True
                              </s:Boolean>
                           </DiscreteObjectKeyFrame.Value>
                        </DiscreteObjectKeyFrame>
                     </ObjectAnimationUsingKeyFrames>
                  </Storyboard>
               </VisualState>

               <VisualStateGroup.Transitions>
                  <VisualTransition From="RequestsPending"
                                    To="NoPendingRequests">
                     <Storyboard>
                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="loadingIndicator"
                                                       Storyboard.TargetProperty="RequestsPending">
                           <DiscreteObjectKeyFrame KeyTime="00:00:00.0">
                              <DiscreteObjectKeyFrame.Value>
                                 <s:Boolean>
                                    False
                                 </s:Boolean>
                              </DiscreteObjectKeyFrame.Value>
                           </DiscreteObjectKeyFrame>
                        </ObjectAnimationUsingKeyFrames>
                     </Storyboard>
                  </VisualTransition>
               </VisualStateGroup.Transitions>
            </VisualStateGroup>

            <VisualStateGroup x:Name="LicensingStates">
               <VisualState x:Name="Licensed" />

               <VisualState x:Name="NotLicensed">
                  <Storyboard>
                     <ObjectAnimationUsingKeyFrames Storyboard.TargetName="licensingMessage"
                                                    Storyboard.TargetProperty="Visibility"
                                                    Duration="00:00:0.0">
                        <DiscreteObjectKeyFrame KeyTime="00:00:0.0">
                           <DiscreteObjectKeyFrame.Value>
                              <Visibility>Visible</Visibility>
                           </DiscreteObjectKeyFrame.Value>
                        </DiscreteObjectKeyFrame>
                     </ObjectAnimationUsingKeyFrames>
                  </Storyboard>
               </VisualState>
            </VisualStateGroup>

            <VisualStateGroup x:Name="DataNavigationPaneStates">
               <VisualState x:Name="DataNavigationPaneHidden">
                  <Storyboard>
                     <DoubleAnimation Storyboard.TargetName="DataNavPane"
                                      Storyboard.TargetProperty="Opacity"
                                      To="0"
                                      Duration="00:00:00.150" />

                     <ObjectAnimationUsingKeyFrames Storyboard.TargetName="DataNavPane"
                                                    Storyboard.TargetProperty="Visibility"
                                                    Duration="00:00:0.0">
                        <DiscreteObjectKeyFrame KeyTime="00:00:0.150">
                           <DiscreteObjectKeyFrame.Value>
                              <Visibility>Collapsed</Visibility>
                           </DiscreteObjectKeyFrame.Value>
                        </DiscreteObjectKeyFrame>
                     </ObjectAnimationUsingKeyFrames>
                  </Storyboard>
               </VisualState>


               <VisualState x:Name="DataNavigationPaneVisible">
                  <Storyboard>
                     <DoubleAnimation Storyboard.TargetName="DataNavPane"
                                      Storyboard.TargetProperty="Opacity"
                                      From="0"
                                      To="1"
                                      Duration="00:00:00.150" />

                     <ObjectAnimationUsingKeyFrames Storyboard.TargetName="DataNavPane"
                                                    Storyboard.TargetProperty="Visibility"
                                                    Duration="00:00:0.0">
                        <DiscreteObjectKeyFrame KeyTime="00:00:0.0">
                           <DiscreteObjectKeyFrame.Value>
                              <Visibility>Visible</Visibility>
                           </DiscreteObjectKeyFrame.Value>
                        </DiscreteObjectKeyFrame>
                     </ObjectAnimationUsingKeyFrames>
                  </Storyboard>
               </VisualState>
            </VisualStateGroup>
         </VisualStateManager.VisualStateGroups>

         <Grid>
            <Grid.ColumnDefinitions>
               <ColumnDefinition />
               <ColumnDefinition Width="Auto" />
            </Grid.ColumnDefinitions>
            <Grid.RowDefinitions>
               <RowDefinition Height="Auto" />
               <RowDefinition />
            </Grid.RowDefinitions>
            <Grid Grid.Column="0"
                  Grid.ColumnSpan="2"
                  Grid.Row="0"
                  Height="50"
                  Background="{StaticResource SilverlightThemeToolPaneBackgroundBrush}"
                  Visibility="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=ToolPaneVisibility}">
               <sllb:FilterControl x:Name="FilterControl"
                                   HorizontalAlignment="Left"
                                   Margin="10,0,0,0"
                                   Height="28"
                                   Width="225"
                                   DataSourceFilterExpression="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=FilterExpression, Mode=TwoWay}"
                                   sllb:SearchTextBox.FilteredFieldNames="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=(sllb:SearchTextBox.FilteredFieldNames)}"
                                   sllb:SearchTextBox.TooComplexText="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=(sllb:SearchTextBox.TooComplexText)}" />
               <Rectangle Height="1"
                          VerticalAlignment="Bottom"
                          Fill="#FF8399A9" />
            </Grid>

            <ScrollViewer x:Name="ScrollViewer"
                          IsTabStop="False"
                          TabNavigation="Once"
                          Grid.Column="0"
                          Grid.Row="1"
                          HorizontalScrollBarVisibility="{TemplateBinding HorizontalScrollBarVisibility}"
                          VerticalScrollBarVisibility="{TemplateBinding VerticalScrollBarVisibility}"
                          Padding="{TemplateBinding Padding}"
                          Style="{StaticResource SilverlightThemeScrollViewerStyle}">
               <sllb:ItemsPresenter />
            </ScrollViewer>

            <sllb:LoadingIndicator x:Name="loadingIndicator"
                                   Grid.Column="0"
                                   Grid.Row="1" />

            <Grid x:Name="licensingMessage"
                  Grid.RowSpan="3"
                  Grid.ColumnSpan="2"
                  Visibility="Collapsed"
                  Background="#80FFFFFF">
               <Grid HorizontalAlignment="Center"
                     VerticalAlignment="Center"
                     Width="250">
                  <Grid.RowDefinitions>
                     <RowDefinition Height="0.27*" />
                     <RowDefinition Height="1" />
                     <RowDefinition Height="0.69*" />
                  </Grid.RowDefinitions>
                  <Border CornerRadius="6"
                          Grid.RowSpan="3">
                     <Border.Background>
                        <LinearGradientBrush EndPoint="0.5,1"
                                             StartPoint="0.5,0">
                           <GradientStop Color="#FFCA4800"
                                         Offset="1" />
                           <GradientStop Color="#FFFF9B09" />
                        </LinearGradientBrush>
                     </Border.Background>
                  </Border>
                  <Border BorderBrush="#66000000"
                          BorderThickness="1"
                          CornerRadius="6"
                          Grid.RowSpan="3" />
                  <Border BorderBrush="#33FFFFFF"
                          BorderThickness="1"
                          CornerRadius="5"
                          Margin="1"
                          Grid.RowSpan="3" />
                  <Border Opacity="0.08"
                          CornerRadius="6"
                          Grid.RowSpan="3">
                     <Border.Background>
                        <LinearGradientBrush StartPoint="-0.015,0.1"
                                             EndPoint="9.187,9.236"
                                             SpreadMethod="Repeat"
                                             MappingMode="Absolute">
                           <GradientStop Offset="0"
                                         Color="Transparent" />
                           <GradientStop Color="Transparent"
                                         Offset="0.5" />
                           <GradientStop Offset="0.5"
                                         Color="White" />
                           <GradientStop Offset="1"
                                         Color="White" />
                        </LinearGradientBrush>
                     </Border.Background>
                  </Border>
                  <Border Background="#66000000"
                          Grid.Row="1"
                          Margin="10,0" />
                  <TextBlock HorizontalAlignment="Left"
                             Margin="10,6,0,0"
                             TextWrapping="Wrap"
                             Text="Invalid License / Trial Expired"
                             VerticalAlignment="Bottom"
                             Foreground="White"
                             FontSize="16" />
                  <RichTextBox Style="{StaticResource SilverlightThemeLicensingStateRichTextBoxStyle}"
                               Margin="10,6,0,10"
                               Grid.Row="2">
                     <Paragraph>
                        <Run>A valid license key must be provided in order to license Xceed Ultimate ListBox for Silverlight. Refer to the</Run>
                        <Hyperlink NavigateUri="http://doc.xceedsoft.com/products/XceedSilverlightListBox/Licensing.html"
                                   TargetName="_blank"
                                   Foreground="White"
                                   MouseOverForeground="#550000">Licensing topic</Hyperlink>
                        <Run>in the documentation for more information.</Run>
                     </Paragraph>
                  </RichTextBox>
               </Grid>
            </Grid>

            <Grid x:Name="DataNavPane"
                  Visibility="Collapsed"
                  Grid.Row="1"
                  Grid.RowSpan="2">

               <Grid.RowDefinitions>
                  <RowDefinition Height="32" />
                  <RowDefinition />
               </Grid.RowDefinitions>
               <Border Background="{StaticResource SilverlightThemeListBoxGroupHearderItemBackgroundBrush}"
                       Grid.RowSpan="2" />

               <sllb:DataNavigationControl x:Name="DataNavControl"
                                           DataNavigationHost="{Binding RelativeSource={RelativeSource TemplatedParent}}"
                                           Grid.Row="1" />

               <Button x:Name="HidePaneButton"
                       Grid.Row="0"
                       HorizontalAlignment="Right"
                       VerticalAlignment="Top"
                       Padding="5"
                       Margin="5"
                       Style="{StaticResource SilverlightThemeNavigationButtonStyle}"
                       Command="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=HideDataNavigationPaneCommand}">
                  <Path Height="9.33"
                        Width="9.33"
                        Stretch="Fill"
                        Data="M 7.333343505859375,-0.6666641235351562 C7.333343505859375,-0.6666641235351562 4,2.6650009155273438 4,2.6650009155273438 4,2.6650009155273438 0.666656494140625,-0.6666641235351562 0.666656494140625,-0.6666641235351562 0.666656494140625,-0.6666641235351562 -0.666656494140625,0.6666641235351562 -0.666656494140625,0.6666641235351562 -0.666656494140625,0.6666641235351562 2.665008544921875,4 2.665008544921875,4 2.665008544921875,4 -0.666656494140625,7.333335876464844 -0.666656494140625,7.333335876464844 -0.666656494140625,7.333335876464844 0.666656494140625,8.666664123535156 0.666656494140625,8.666664123535156 0.666656494140625,8.666664123535156 4,5.334999084472656 4,5.334999084472656 4,5.334999084472656 7.333343505859375,8.666664123535156 7.333343505859375,8.666664123535156 7.333343505859375,8.666664123535156 8.666656494140625,7.333335876464844 8.666656494140625,7.333335876464844 8.666656494140625,7.333335876464844 5.334991455078125,4 5.334991455078125,4 5.334991455078125,4 8.666656494140625,0.6666641235351562 8.666656494140625,0.6666641235351562 8.666656494140625,0.6666641235351562 7.333343505859375,-0.6666641235351562 7.333343505859375,-0.6666641235351562 z"
                        Fill="#A6A6A6" />
               </Button>
            </Grid>
         </Grid>
      </Border>
   </ControlTemplate>

   <!--**************************
    * TEMPLATE: ListBoxItem
    ************************** -->
   <ControlTemplate x:Key="SilverlightThemeListBoxItemTemplate"
                    TargetType="sllb:ListBoxItem">
      <Border Background="{TemplateBinding Background}"
              BorderBrush="{TemplateBinding BorderBrush}"
              BorderThickness="{TemplateBinding BorderThickness}">
            <VisualStateManager.VisualStateGroups>
               <VisualStateGroup x:Name="CommonStates">
                  <VisualState x:Name="Normal" />
                  <VisualState x:Name="MouseOver">
                     <Storyboard>
                        <DoubleAnimation Storyboard.TargetName="fillColor"
                                         Storyboard.TargetProperty="Opacity"
                                         Duration="0"
                                         To=".35" />
                     </Storyboard>
                  </VisualState>
                  <VisualState x:Name="Disabled">
                     <Storyboard>
                        <DoubleAnimation Storyboard.TargetName="contentPresenter"
                                         Storyboard.TargetProperty="Opacity"
                                         Duration="0"
                                         To=".55" />
                     </Storyboard>
                  </VisualState>
               </VisualStateGroup>
               <VisualStateGroup x:Name="SelectionStates">
                  <VisualState x:Name="Unselected" />
                  <VisualState x:Name="Selected">
                     <Storyboard>
                        <DoubleAnimation Storyboard.TargetName="fillColor2"
                                         Storyboard.TargetProperty="Opacity"
                                         Duration="0"
                                         To=".75" />
                     </Storyboard>
                  </VisualState>
               </VisualStateGroup>
               <VisualStateGroup x:Name="FocusStates">
                  <VisualState x:Name="Focused">
                     <Storyboard>
                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="FocusVisualElement"
                                                       Storyboard.TargetProperty="Visibility"
                                                       Duration="0">
                           <DiscreteObjectKeyFrame KeyTime="0">
                              <DiscreteObjectKeyFrame.Value>
                                 <Visibility>Visible</Visibility>
                              </DiscreteObjectKeyFrame.Value>
                           </DiscreteObjectKeyFrame>
                        </ObjectAnimationUsingKeyFrames>
                     </Storyboard>
                  </VisualState>
                  <VisualState x:Name="Unfocused" />
               </VisualStateGroup>
               <VisualStateGroup x:Name="LoadingStates">
                  <VisualState x:Name="Loaded">
                     <Storyboard>
                        <DoubleAnimation Storyboard.TargetName="contentPresenter"
                                         Storyboard.TargetProperty="Opacity"
                                         Duration="00:00:00.250"
                                         To="1" />
                     </Storyboard>
                  </VisualState>
                  <VisualState x:Name="Loading">
                     <Storyboard>
                        <DoubleAnimation Storyboard.TargetName="contentPresenter"
                                         Storyboard.TargetProperty="Opacity"
                                         Duration="0"
                                         To="0" />
                     </Storyboard>
                  </VisualState>
               </VisualStateGroup>

            </VisualStateManager.VisualStateGroups>
         <Grid>
            <Rectangle x:Name="fillColor"
                       Opacity="0"
                       Fill="#FFBADDE9"
                       IsHitTestVisible="False"
                       RadiusX="1"
                       RadiusY="1" />
            <Rectangle x:Name="fillColor2"
                       Opacity="0"
                       Fill="#FFBADDE9"
                       IsHitTestVisible="False"
                       RadiusX="1"
                       RadiusY="1" />
            <ContentPresenter x:Name="contentPresenter"
                              Content="{TemplateBinding Content}"
                              ContentTemplate="{TemplateBinding ContentTemplate}"
                              HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}"
                              VerticalAlignment="{TemplateBinding VerticalContentAlignment}"
                              Margin="{TemplateBinding Padding}" />
            <Rectangle x:Name="FocusVisualElement"
                       Stroke="#FF6DBDD1"
                       StrokeThickness="1"
                       Visibility="Collapsed"
                       RadiusX="1"
                       RadiusY="1" />
         </Grid>
      </Border>
   </ControlTemplate>

   <!--**************************
    * TEMPLATE: ListBoxGroupHeader
    ************************** -->
   <ControlTemplate x:Key="SilverlightThemeListBoxGroupHeaderTemplate"
                    TargetType="sllb:ListBoxGroupHeader">
      <Grid>
         <VisualStateManager.VisualStateGroups>
            <VisualStateGroup x:Name="CommonStates">
               <VisualState x:Name="Disabled">
                  <Storyboard>
                     <DoubleAnimation Storyboard.TargetName="contentPresenter"
                                      Storyboard.TargetProperty="Opacity"
                                      Duration="0"
                                      To=".55" />
                     <DoubleAnimation Storyboard.TargetName="HorizontalContentPresenter"
                                      Storyboard.TargetProperty="Opacity"
                                      Duration="0"
                                      To=".55" />
                  </Storyboard>
               </VisualState>
               <VisualState x:Name="Normal" />
               <VisualState x:Name="MouseOver" />
            </VisualStateGroup>

            <VisualStateGroup x:Name="FocusStates">
               <VisualState x:Name="Unfocused" />
               <VisualState x:Name="Focused" />
            </VisualStateGroup>

            <VisualStateGroup x:Name="SelectionStates">
               <VisualState x:Name="Unselected" />
               <VisualState x:Name="SelectedUnfocused" />
               <VisualState x:Name="Selected" />
            </VisualStateGroup>

            <VisualStateGroup x:Name="LoadingStates">
               <VisualState x:Name="Loaded">
                  <Storyboard>
                     <DoubleAnimation Storyboard.TargetName="HorizontalContentPresenter"
                                      Storyboard.TargetProperty="Opacity"
                                      Duration="0"
                                      To="1" />
                     <DoubleAnimation Storyboard.TargetName="contentPresenter"
                                      Storyboard.TargetProperty="Opacity"
                                      Duration="0"
                                      To="1" />
                  </Storyboard>
               </VisualState>
               <VisualState x:Name="Loading">
                  <Storyboard>
                     <DoubleAnimation Storyboard.TargetName="HorizontalContentPresenter"
                                      Storyboard.TargetProperty="Opacity"
                                      Duration="0"
                                      To="0" />
                     <DoubleAnimation Storyboard.TargetName="contentPresenter"
                                      Storyboard.TargetProperty="Opacity"
                                      Duration="0"
                                      To="0" />
                  </Storyboard>
               </VisualState>
            </VisualStateGroup>

            <VisualStateGroup x:Name="LayoutModeStates">
               <VisualState x:Name="Vertical" />
               <VisualState x:Name="Horizontal">
                  <Storyboard>
                     <ObjectAnimationUsingKeyFrames Storyboard.TargetName="HorizontalLayoutGrid"
                                                    Storyboard.TargetProperty="Visibility"
                                                    Duration="00:00:0.0">
                        <DiscreteObjectKeyFrame KeyTime="00:00:0.0">
                           <DiscreteObjectKeyFrame.Value>
                              <Visibility>Visible</Visibility>
                           </DiscreteObjectKeyFrame.Value>
                        </DiscreteObjectKeyFrame>
                     </ObjectAnimationUsingKeyFrames>
                     <ObjectAnimationUsingKeyFrames Storyboard.TargetName="VerticalLayoutGrid"
                                                    Storyboard.TargetProperty="Visibility"
                                                    Duration="00:00:0.0">
                        <DiscreteObjectKeyFrame KeyTime="00:00:0.0">
                           <DiscreteObjectKeyFrame.Value>
                              <Visibility>Collapsed</Visibility>
                           </DiscreteObjectKeyFrame.Value>
                        </DiscreteObjectKeyFrame>
                     </ObjectAnimationUsingKeyFrames>
                  </Storyboard>
               </VisualState>
               <VisualState x:Name="Floating">
                  <Storyboard>
                     <ObjectAnimationUsingKeyFrames Storyboard.TargetName="HorizontalLayoutGrid"
                                                    Storyboard.TargetProperty="Visibility"
                                                    Duration="00:00:0.0">
                        <DiscreteObjectKeyFrame KeyTime="00:00:0.0">
                           <DiscreteObjectKeyFrame.Value>
                              <Visibility>Visible</Visibility>
                           </DiscreteObjectKeyFrame.Value>
                        </DiscreteObjectKeyFrame>
                     </ObjectAnimationUsingKeyFrames>
                     <ObjectAnimationUsingKeyFrames Storyboard.TargetName="VerticalLayoutGrid"
                                                    Storyboard.TargetProperty="Visibility"
                                                    Duration="00:00:0.0">
                        <DiscreteObjectKeyFrame KeyTime="00:00:0.0">
                           <DiscreteObjectKeyFrame.Value>
                              <Visibility>Collapsed</Visibility>
                           </DiscreteObjectKeyFrame.Value>
                        </DiscreteObjectKeyFrame>
                     </ObjectAnimationUsingKeyFrames>
                  </Storyboard>
               </VisualState>
            </VisualStateGroup>

         </VisualStateManager.VisualStateGroups>
         <Grid x:Name="VerticalLayoutGrid"
               Visibility="Visible">
            <Border x:Name="rootBorder"
                    BorderBrush="{TemplateBinding BorderBrush}"
                    BorderThickness="{TemplateBinding BorderThickness}"
                    Background="{TemplateBinding Background}">

               <sllb:HierarchicalGroupValueControl x:Name="contentPresenter"
                                                   Margin="{TemplateBinding Padding}"
                                                   HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}"
                                                   VerticalAlignment="{TemplateBinding VerticalContentAlignment}"
                                                   GroupValueDataTemplates="{TemplateBinding GroupValueDataTemplates}"
                                                   ItemsSource="{Binding Path=FieldNameValuePairs}"
                                                   sllb:ListBoxContainer.LayoutMode="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=(sllb:ListBoxContainer.LayoutMode)}">
                  <sllb:HierarchicalGroupValueControl.ItemsPanel>
                     <ItemsPanelTemplate>
                        <StackPanel Orientation="Horizontal"></StackPanel>
                     </ItemsPanelTemplate>
                  </sllb:HierarchicalGroupValueControl.ItemsPanel>
               </sllb:HierarchicalGroupValueControl>
            </Border>
            <StackPanel Orientation="Horizontal"
                        HorizontalAlignment="Right"
                        Margin="0,0,5,0">

               <Button Style="{StaticResource SilverlightThemeNavigationButtonStyle}"
                       ContentTemplate="{StaticResource SilverlightThemeDataNavigationIcon}"
                       Margin="0,5,10,5"
                       Padding="5"
                       Command="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=ParentListBox.ShowDataNavigationPaneCommand}" />

               <Button x:Name="PreviousButton"
                       BorderThickness="1"
                       IsTabStop="False"
                       Command="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=NavigateToPreviousGroupCommand}"
                       Style="{StaticResource SilverlightThemeNavigationButtonStyle}"
                       Margin="0,5,3,5"
                       Padding="5">
                  <Path Margin="3,1"
                        RenderTransformOrigin="0.5,0.5"
                        HorizontalAlignment="Center"
                        VerticalAlignment="Center"
                        Height="7"
                        Width="14"
                        Stretch="Fill"
                        Opacity="1"
                        Data="M 7,0 C7,0 0,7 0,7 0,7 14,7 14,7 14,7 7,0 7,0 z"
                        UseLayoutRounding="False">
                     <Path.Effect>
                        <DropShadowEffect BlurRadius="2"
                                          ShadowDepth="1"
                                          Color="White" />
                     </Path.Effect>
                     <Path.Fill>
                        <LinearGradientBrush EndPoint="0.5,1"
                                             StartPoint="0.5,0">
                           <GradientStop Color="#FF9EADC1"
                                         Offset="1" />
                           <GradientStop Color="#FFC6CFDA" />
                        </LinearGradientBrush>
                     </Path.Fill>
                  </Path>
               </Button>

               <Button x:Name="NextButton"
                       IsTabStop="False"
                       Command="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=NavigateToNextGroupCommand}"
                       Style="{StaticResource SilverlightThemeNavigationButtonStyle}"
                       Margin="0,5,0,5"
                       Padding="5">
                  <Path Margin="3,1"
                        HorizontalAlignment="Center"
                        VerticalAlignment="Center"
                        Height="7"
                        Width="14"
                        Stretch="Fill"
                        Opacity="1"
                        Data="M 7,7 C7,7 14,0 14,0 14,0 0,0 0,0 0,0 7,7 7,7 z"
                        UseLayoutRounding="False">
                     <Path.Effect>
                        <DropShadowEffect BlurRadius="2"
                                          ShadowDepth="1"
                                          Color="White" />
                     </Path.Effect>
                     <Path.Fill>
                        <LinearGradientBrush EndPoint="0.5,1"
                                             StartPoint="0.5,0">
                           <GradientStop Color="#FF9EADC1"
                                         Offset="1" />
                           <GradientStop Color="#FFC6CFDA" />
                        </LinearGradientBrush>
                     </Path.Fill>
                  </Path>
               </Button>
            </StackPanel>

         </Grid>

         <Grid x:Name="HorizontalLayoutGrid"
               Visibility="Collapsed">
            <Grid.ColumnDefinitions>
               <ColumnDefinition Width="*" />
               <ColumnDefinition Width="40" />
               <ColumnDefinition Width="*" />
            </Grid.ColumnDefinitions>
            <Grid.RowDefinitions>
               <RowDefinition Height="*" />
               <RowDefinition Height="Auto" />
            </Grid.RowDefinitions>

            <Border x:Name="HorizontalRootBorder"
                    Grid.RowSpan="2"
                    Grid.ColumnSpan="3"
                    BorderBrush="{TemplateBinding BorderBrush}"
                    BorderThickness="{TemplateBinding BorderThickness}"
                    Background="{TemplateBinding Background}" />

            <Button x:Name="HorizontalPreviousButton"
                    Grid.Row="1"
                    Grid.Column="0"
                    BorderThickness="1"
                    IsTabStop="False"
                    Command="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=NavigateToPreviousGroupCommand}"
                    Style="{StaticResource SilverlightThemeNavigationButtonStyle}">
               <Path RenderTransformOrigin="0.5,0.5"
                     HorizontalAlignment="Center"
                     VerticalAlignment="Center"
                     Width="7"
                     Stretch="Fill"
                     Opacity="1"
                     Data="M 306,597 C306,597 313,590 313,590 313,590 313,605 313,605 313,605 306,597 306,597 z"
                     UseLayoutRounding="False">
                  <Path.Effect>
                     <DropShadowEffect BlurRadius="2"
                                       ShadowDepth="1"
                                       Color="White" />
                  </Path.Effect>
                  <Path.Fill>
                     <LinearGradientBrush EndPoint="0.5,1"
                                          StartPoint="0.5,0">
                        <GradientStop Color="#FF9EADC1"
                                      Offset="1" />
                        <GradientStop Color="#FFC6CFDA" />
                     </LinearGradientBrush>
                  </Path.Fill>
               </Path>
            </Button>

            <Button x:Name="HorizontalNextButton"
                    Grid.Row="1"
                    Grid.Column="2"
                    IsTabStop="False"
                    Command="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=NavigateToNextGroupCommand}"
                    Style="{StaticResource SilverlightThemeNavigationButtonStyle}">
               <Path RenderTransformOrigin="0.5,0.5"
                     HorizontalAlignment="Center"
                     VerticalAlignment="Center"
                     Width="7"
                     Stretch="Fill"
                     Opacity="1"
                     Data="M 401,598 C401,598 394,605 394,605 394,605 394,590 394,590 394,590 401,598 401,598 z"
                     UseLayoutRounding="False">
                  <Path.Effect>
                     <DropShadowEffect BlurRadius="2"
                                       ShadowDepth="1"
                                       Color="White" />
                  </Path.Effect>
                  <Path.Fill>
                     <LinearGradientBrush EndPoint="0.5,1"
                                          StartPoint="0.5,0">
                        <GradientStop Color="#FF9EADC1"
                                      Offset="1" />
                        <GradientStop Color="#FFC6CFDA" />
                     </LinearGradientBrush>
                  </Path.Fill>
               </Path>
            </Button>

            <Button Style="{StaticResource SilverlightThemeNavigationButtonStyle}"
                    Grid.Row="1"
                    Grid.Column="1"
                    ContentTemplate="{StaticResource SilverlightThemeDataNavigationIcon}"
                    Padding="5"
                    Command="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=ParentListBox.ShowDataNavigationPaneCommand}" />

            <sllb:HierarchicalGroupValueControl x:Name="HorizontalContentPresenter"
                                                Grid.Row="0"
                                                Grid.Column="0"
                                                Grid.ColumnSpan="3"
                                                Margin="{TemplateBinding Padding}"
                                                HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}"
                                                VerticalAlignment="{TemplateBinding VerticalContentAlignment}"
                                                GroupValueDataTemplates="{TemplateBinding GroupValueDataTemplates}"
                                                ItemsSource="{Binding Path=FieldNameValuePairs}"
                                                sllb:ListBoxContainer.LayoutMode="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=(sllb:ListBoxContainer.LayoutMode)}">
               <sllb:HierarchicalGroupValueControl.ItemsPanel>
                  <ItemsPanelTemplate>
                     <StackPanel Orientation="Vertical"></StackPanel>
                  </ItemsPanelTemplate>
               </sllb:HierarchicalGroupValueControl.ItemsPanel>
            </sllb:HierarchicalGroupValueControl>

         </Grid>
      </Grid>
   </ControlTemplate>

   <!--**************************
    * TEMPLATE: HierarchicalGroupValueItem
    ************************** -->
   <ControlTemplate x:Key="SilverlightThemeHierarchicalGroupValueItemTemplate"
                    TargetType="sllb:HierarchicalGroupValueItem">
      <Grid>
         <VisualStateManager.VisualStateGroups>
            <VisualStateGroup x:Name="GroupValueLevelStates">
               <VisualState x:Name="None" />

               <VisualState x:Name="Root" />

               <VisualState x:Name="Leaf">
                  <Storyboard>
                     <ObjectAnimationUsingKeyFrames Storyboard.TargetName="leafStateGridLayout"
                                                    Storyboard.TargetProperty="Visibility"
                                                    Duration="00:00:0.0">
                        <DiscreteObjectKeyFrame KeyTime="00:00:0.0">
                           <DiscreteObjectKeyFrame.Value>
                              <Visibility>Collapsed</Visibility>
                           </DiscreteObjectKeyFrame.Value>
                        </DiscreteObjectKeyFrame>
                     </ObjectAnimationUsingKeyFrames>
                  </Storyboard>
               </VisualState>

               <VisualState x:Name="RootAndLeaf">
                  <Storyboard>
                     <ObjectAnimationUsingKeyFrames Storyboard.TargetName="leafStateGridLayout"
                                                    Storyboard.TargetProperty="Visibility"
                                                    Duration="00:00:0.0">
                        <DiscreteObjectKeyFrame KeyTime="00:00:0.0">
                           <DiscreteObjectKeyFrame.Value>
                              <Visibility>Collapsed</Visibility>
                           </DiscreteObjectKeyFrame.Value>
                        </DiscreteObjectKeyFrame>
                     </ObjectAnimationUsingKeyFrames>
                  </Storyboard>
               </VisualState>
            </VisualStateGroup>
         </VisualStateManager.VisualStateGroups>

         <Border x:Name="rootBorder"
                 Margin="3,0">
            <Grid>
               <Grid.ColumnDefinitions>
                  <ColumnDefinition />
                  <ColumnDefinition />
               </Grid.ColumnDefinitions>

               <ContentPresenter Grid.Column="0"
                                 Content="{TemplateBinding DataContext}"
                                 ContentTemplate="{TemplateBinding ContentTemplate}" />

               <Grid x:Name="leafStateGridLayout"
                     Grid.Column="1"
                     Margin="6,0,0,0">
                  <Grid x:Name="separatorLayoutGrid"
                        Visibility="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=ParentHierarchicalGroupValueControl.SeparatorVisibility}">
                     <TextBlock Foreground="{TemplateBinding Foreground}"
                                FontFamily="{TemplateBinding FontFamily}"
                                FontSize="{TemplateBinding FontSize}"
                                Text="-" />
                  </Grid>
               </Grid>
            </Grid>
         </Border>
      </Grid>

   </ControlTemplate>

   <!--**************************
    * TEMPLATE: LoadingIndicator
    ************************** -->
   <ControlTemplate x:Key="SilverlightThemeLoadingIndicatorTemplate"
                    TargetType="sllb:LoadingIndicator">
      <Border x:Name="loadingGlyphBackground"
              IsHitTestVisible="False"
              Opacity="0">
         <VisualStateManager.VisualStateGroups>
            <VisualStateGroup x:Name="RequestStates">

               <VisualState x:Name="NoPendingRequests" />

               <VisualState x:Name="RequestsPending">
                  <Storyboard>
                     <DoubleAnimation Storyboard.TargetName="loadingGlyphBackground"
                                      Storyboard.TargetProperty="Opacity"
                                      To="1"
                                      Duration="00:00:00.350" />
                     <DoubleAnimation Storyboard.TargetName="loadingGlyph"
                                      Storyboard.TargetProperty="Opacity"
                                      To="1"
                                      Duration="00:00:00.350" />
                  </Storyboard>
               </VisualState>

               <VisualStateGroup.Transitions>
                  <VisualTransition From="RequestsPending"
                                    To="NoPendingRequests">
                     <Storyboard>
                        <DoubleAnimation Storyboard.TargetName="loadingGlyphBackground"
                                         Storyboard.TargetProperty="Opacity"
                                         BeginTime="00:00:0.5"
                                         To="0"
                                         Duration="00:00:00.350" />
                        <DoubleAnimation Storyboard.TargetName="loadingGlyph"
                                         Storyboard.TargetProperty="Opacity"
                                         BeginTime="00:00:0.5"
                                         To="0"
                                         Duration="00:00:00.350" />
                     </Storyboard>
                  </VisualTransition>
               </VisualStateGroup.Transitions>
            </VisualStateGroup>
         </VisualStateManager.VisualStateGroups>

         <sllb:LoadingSpinner x:Name="loadingGlyph"
                              VerticalAlignment="{TemplateBinding VerticalContentAlignment}"
                              HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}"
                              Opacity="0"
                              Value="{TemplateBinding AnimatedValue}" />
      </Border>
   </ControlTemplate>

   <!--**************************
    * TEMPLATE: LoadingSpinner
    ************************** -->
   <ControlTemplate x:Key="SilverlightThemeLoadingSpinnerTemplate"
                    TargetType="sllb:LoadingSpinner">
      <Border Background="{TemplateBinding Background}"
              BorderBrush="{TemplateBinding BorderBrush}"
              BorderThickness="{TemplateBinding BorderThickness}"
              Width="40"
              Height="40">
         <Grid>
            <Grid.Resources>
               <sllb:RatioToOpacityConverter x:Key="SilverlightThemeRatioToOpacityConverter" />
            </Grid.Resources>

            <!-- Shadows -->
            <Border x:Name="14_Shadow"
                    HorizontalAlignment="Center"
                    Width="4"
                    RenderTransformOrigin="0.5,2.45"
                    CornerRadius="2.4"
                    Background="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=ShadowBrush }"
                    UseLayoutRounding="False"
                    Height="8"
                    VerticalAlignment="Top">
               <Border.RenderTransform>
                  <RotateTransform Angle="336" />
               </Border.RenderTransform>
            </Border>
            <Border x:Name="13_Shadow"
                    HorizontalAlignment="Center"
                    Width="4"
                    RenderTransformOrigin="0.5,2.45"
                    CornerRadius="2.4"
                    Background="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=ShadowBrush }"
                    UseLayoutRounding="False"
                    Height="8"
                    VerticalAlignment="Top">
               <Border.RenderTransform>
                  <RotateTransform Angle="312" />
               </Border.RenderTransform>
            </Border>
            <Border x:Name="12_Shadow"
                    HorizontalAlignment="Center"
                    Width="4"
                    RenderTransformOrigin="0.5,2.45"
                    CornerRadius="2.4"
                    Background="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=ShadowBrush }"
                    UseLayoutRounding="False"
                    Height="8"
                    VerticalAlignment="Top">
               <Border.RenderTransform>
                  <RotateTransform Angle="288" />
               </Border.RenderTransform>
            </Border>
            <Border x:Name="11_Shadow"
                    HorizontalAlignment="Center"
                    Width="4"
                    RenderTransformOrigin="0.5,2.45"
                    CornerRadius="2.4"
                    Background="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=ShadowBrush }"
                    UseLayoutRounding="False"
                    Height="8"
                    VerticalAlignment="Top">
               <Border.RenderTransform>
                  <RotateTransform Angle="264" />
               </Border.RenderTransform>
            </Border>
            <Border x:Name="10_Shadow"
                    HorizontalAlignment="Center"
                    Width="4"
                    RenderTransformOrigin="0.5,2.45"
                    CornerRadius="2.4"
                    Background="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=ShadowBrush }"
                    UseLayoutRounding="False"
                    Height="8"
                    VerticalAlignment="Top">
               <Border.RenderTransform>
                  <RotateTransform Angle="240" />
               </Border.RenderTransform>
            </Border>
            <Border x:Name="09_Shadow"
                    HorizontalAlignment="Center"
                    Width="4"
                    RenderTransformOrigin="0.5,2.45"
                    CornerRadius="2.4"
                    Background="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=ShadowBrush }"
                    UseLayoutRounding="False"
                    Height="8"
                    VerticalAlignment="Top">
               <Border.RenderTransform>
                  <RotateTransform Angle="216" />
               </Border.RenderTransform>
            </Border>
            <Border x:Name="08_Shadow"
                    HorizontalAlignment="Center"
                    Width="4"
                    RenderTransformOrigin="0.5,2.45"
                    CornerRadius="2.4"
                    Background="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=ShadowBrush }"
                    UseLayoutRounding="False"
                    Height="8"
                    VerticalAlignment="Top">
               <Border.RenderTransform>
                  <RotateTransform Angle="192" />
               </Border.RenderTransform>
            </Border>
            <Border x:Name="07_Shadow"
                    HorizontalAlignment="Center"
                    Width="4"
                    RenderTransformOrigin="0.5,2.45"
                    CornerRadius="2.4"
                    Background="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=ShadowBrush }"
                    UseLayoutRounding="False"
                    Height="8"
                    VerticalAlignment="Top">
               <Border.RenderTransform>
                  <RotateTransform Angle="168" />
               </Border.RenderTransform>
            </Border>
            <Border x:Name="06_Shadow"
                    HorizontalAlignment="Center"
                    Width="4"
                    RenderTransformOrigin="0.5,2.45"
                    CornerRadius="2.4"
                    Background="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=ShadowBrush }"
                    UseLayoutRounding="False"
                    Height="8"
                    VerticalAlignment="Top">
               <Border.RenderTransform>
                  <RotateTransform Angle="144" />
               </Border.RenderTransform>
            </Border>
            <Border x:Name="05_Shadow"
                    HorizontalAlignment="Center"
                    Width="4"
                    RenderTransformOrigin="0.5,2.45"
                    CornerRadius="2.4"
                    Background="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=ShadowBrush }"
                    UseLayoutRounding="False"
                    Height="8"
                    VerticalAlignment="Top">
               <Border.RenderTransform>
                  <RotateTransform Angle="120" />
               </Border.RenderTransform>
            </Border>
            <Border x:Name="04_Shadow"
                    HorizontalAlignment="Center"
                    Width="4"
                    RenderTransformOrigin="0.5,2.45"
                    CornerRadius="2.4"
                    Background="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=ShadowBrush }"
                    UseLayoutRounding="False"
                    Height="8"
                    VerticalAlignment="Top">
               <Border.RenderTransform>
                  <RotateTransform Angle="96" />
               </Border.RenderTransform>
            </Border>
            <Border x:Name="03_Shadow"
                    HorizontalAlignment="Center"
                    Width="4"
                    RenderTransformOrigin="0.5,2.45"
                    CornerRadius="2.4"
                    Background="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=ShadowBrush }"
                    UseLayoutRounding="False"
                    Height="8"
                    VerticalAlignment="Top">
               <Border.RenderTransform>
                  <RotateTransform Angle="72" />
               </Border.RenderTransform>
            </Border>
            <Border x:Name="02_Shadow"
                    HorizontalAlignment="Center"
                    Width="4"
                    RenderTransformOrigin="0.5,2.45"
                    CornerRadius="2.4"
                    Background="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=ShadowBrush }"
                    UseLayoutRounding="False"
                    Height="8"
                    VerticalAlignment="Top">
               <Border.RenderTransform>
                  <RotateTransform Angle="48" />
               </Border.RenderTransform>
            </Border>
            <Border x:Name="01_Shadow"
                    HorizontalAlignment="Center"
                    Width="4"
                    RenderTransformOrigin="0.5,2.45"
                    CornerRadius="2.4"
                    Background="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=ShadowBrush }"
                    UseLayoutRounding="False"
                    Height="8"
                    VerticalAlignment="Top">
               <Border.RenderTransform>
                  <RotateTransform Angle="24" />
               </Border.RenderTransform>
            </Border>
            <Border x:Name="00_Shadow"
                    HorizontalAlignment="Center"
                    Width="4"
                    RenderTransformOrigin="0.5,2.45"
                    CornerRadius="2.4"
                    Background="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=ShadowBrush }"
                    Height="8"
                    VerticalAlignment="Top" />

            <!-- Highlights -->
            <Border x:Name="14"
                    HorizontalAlignment="Center"
                    Width="4"
                    RenderTransformOrigin="0.5,2.45"
                    CornerRadius="2.4"
                    Background="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=HighlightBrush }"
                    UseLayoutRounding="False"
                    Height="8"
                    VerticalAlignment="Top"
                    Opacity="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=Ratio, Converter={StaticResource SilverlightThemeRatioToOpacityConverter}, ConverterParameter=336}">
               <Border.RenderTransform>
                  <RotateTransform Angle="336" />
               </Border.RenderTransform>
            </Border>
            <Border x:Name="13"
                    HorizontalAlignment="Center"
                    Width="4"
                    RenderTransformOrigin="0.5,2.45"
                    CornerRadius="2.4"
                    Background="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=HighlightBrush }"
                    UseLayoutRounding="False"
                    Height="8"
                    VerticalAlignment="Top"
                    Opacity="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=Ratio, Converter={StaticResource SilverlightThemeRatioToOpacityConverter}, ConverterParameter=312}">
               <Border.RenderTransform>
                  <RotateTransform Angle="312" />
               </Border.RenderTransform>
            </Border>
            <Border x:Name="12"
                    HorizontalAlignment="Center"
                    Width="4"
                    RenderTransformOrigin="0.5,2.45"
                    CornerRadius="2.4"
                    Background="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=HighlightBrush }"
                    UseLayoutRounding="False"
                    Height="8"
                    VerticalAlignment="Top"
                    Opacity="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=Ratio, Converter={StaticResource SilverlightThemeRatioToOpacityConverter}, ConverterParameter=288}">
               <Border.RenderTransform>
                  <RotateTransform Angle="288" />
               </Border.RenderTransform>
            </Border>
            <Border x:Name="11"
                    HorizontalAlignment="Center"
                    Width="4"
                    RenderTransformOrigin="0.5,2.45"
                    CornerRadius="2.4"
                    Background="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=HighlightBrush }"
                    UseLayoutRounding="False"
                    Height="8"
                    VerticalAlignment="Top"
                    Opacity="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=Ratio, Converter={StaticResource SilverlightThemeRatioToOpacityConverter}, ConverterParameter=264}">
               <Border.RenderTransform>
                  <RotateTransform Angle="264" />
               </Border.RenderTransform>
            </Border>
            <Border x:Name="10"
                    HorizontalAlignment="Center"
                    Width="4"
                    RenderTransformOrigin="0.5,2.45"
                    CornerRadius="2.4"
                    Background="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=HighlightBrush }"
                    UseLayoutRounding="False"
                    Height="8"
                    VerticalAlignment="Top"
                    Opacity="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=Ratio, Converter={StaticResource SilverlightThemeRatioToOpacityConverter}, ConverterParameter=240}">
               <Border.RenderTransform>
                  <RotateTransform Angle="240" />
               </Border.RenderTransform>
            </Border>
            <Border x:Name="09"
                    HorizontalAlignment="Center"
                    Width="4"
                    RenderTransformOrigin="0.5,2.45"
                    CornerRadius="2.4"
                    Background="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=HighlightBrush }"
                    UseLayoutRounding="False"
                    Height="8"
                    VerticalAlignment="Top"
                    Opacity="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=Ratio, Converter={StaticResource SilverlightThemeRatioToOpacityConverter}, ConverterParameter=216}">
               <Border.RenderTransform>
                  <RotateTransform Angle="216" />
               </Border.RenderTransform>
            </Border>
            <Border x:Name="08"
                    HorizontalAlignment="Center"
                    Width="4"
                    RenderTransformOrigin="0.5,2.45"
                    CornerRadius="2.4"
                    Background="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=HighlightBrush }"
                    UseLayoutRounding="False"
                    Height="8"
                    VerticalAlignment="Top"
                    Opacity="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=Ratio, Converter={StaticResource SilverlightThemeRatioToOpacityConverter}, ConverterParameter=192}">
               <Border.RenderTransform>
                  <RotateTransform Angle="192" />
               </Border.RenderTransform>
            </Border>
            <Border x:Name="07"
                    HorizontalAlignment="Center"
                    Width="4"
                    RenderTransformOrigin="0.5,2.45"
                    CornerRadius="2.4"
                    Background="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=HighlightBrush }"
                    UseLayoutRounding="False"
                    Height="8"
                    VerticalAlignment="Top"
                    Opacity="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=Ratio, Converter={StaticResource SilverlightThemeRatioToOpacityConverter}, ConverterParameter=168}">
               <Border.RenderTransform>
                  <RotateTransform Angle="168" />
               </Border.RenderTransform>
            </Border>
            <Border x:Name="06"
                    HorizontalAlignment="Center"
                    Width="4"
                    RenderTransformOrigin="0.5,2.45"
                    CornerRadius="2.4"
                    Background="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=HighlightBrush }"
                    UseLayoutRounding="False"
                    Height="8"
                    VerticalAlignment="Top"
                    Opacity="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=Ratio, Converter={StaticResource SilverlightThemeRatioToOpacityConverter}, ConverterParameter=144}">
               <Border.RenderTransform>
                  <RotateTransform Angle="144" />
               </Border.RenderTransform>
            </Border>
            <Border x:Name="05"
                    HorizontalAlignment="Center"
                    Width="4"
                    RenderTransformOrigin="0.5,2.45"
                    CornerRadius="2.4"
                    Background="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=HighlightBrush }"
                    UseLayoutRounding="False"
                    Height="8"
                    VerticalAlignment="Top"
                    Opacity="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=Ratio, Converter={StaticResource SilverlightThemeRatioToOpacityConverter}, ConverterParameter=120}">
               <Border.RenderTransform>
                  <RotateTransform Angle="120" />
               </Border.RenderTransform>
            </Border>
            <Border x:Name="04"
                    HorizontalAlignment="Center"
                    Width="4"
                    RenderTransformOrigin="0.5,2.45"
                    CornerRadius="2.4"
                    Background="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=HighlightBrush }"
                    UseLayoutRounding="False"
                    Height="8"
                    VerticalAlignment="Top"
                    Opacity="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=Ratio, Converter={StaticResource SilverlightThemeRatioToOpacityConverter}, ConverterParameter=96}">
               <Border.RenderTransform>
                  <RotateTransform Angle="96" />
               </Border.RenderTransform>
            </Border>
            <Border x:Name="03"
                    HorizontalAlignment="Center"
                    Width="4"
                    RenderTransformOrigin="0.5,2.45"
                    CornerRadius="2.4"
                    Background="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=HighlightBrush }"
                    UseLayoutRounding="False"
                    Height="8"
                    VerticalAlignment="Top"
                    Opacity="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=Ratio, Converter={StaticResource SilverlightThemeRatioToOpacityConverter}, ConverterParameter=72}">
               <Border.RenderTransform>
                  <RotateTransform Angle="72" />
               </Border.RenderTransform>
            </Border>
            <Border x:Name="02"
                    HorizontalAlignment="Center"
                    Width="4"
                    RenderTransformOrigin="0.5,2.45"
                    CornerRadius="2.4"
                    Background="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=HighlightBrush }"
                    UseLayoutRounding="False"
                    Height="8"
                    VerticalAlignment="Top"
                    Opacity="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=Ratio, Converter={StaticResource SilverlightThemeRatioToOpacityConverter}, ConverterParameter=48}">
               <Border.RenderTransform>
                  <RotateTransform Angle="48" />
               </Border.RenderTransform>
            </Border>
            <Border x:Name="01"
                    HorizontalAlignment="Center"
                    Width="4"
                    RenderTransformOrigin="0.5,2.45"
                    CornerRadius="2.4"
                    Background="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=HighlightBrush }"
                    UseLayoutRounding="False"
                    Height="8"
                    VerticalAlignment="Top"
                    Opacity="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=Ratio, Converter={StaticResource SilverlightThemeRatioToOpacityConverter}, ConverterParameter=24}">
               <Border.RenderTransform>
                  <RotateTransform Angle="24" />
               </Border.RenderTransform>
            </Border>
            <Border x:Name="00"
                    HorizontalAlignment="Center"
                    Width="4"
                    RenderTransformOrigin="0.5,2.45"
                    CornerRadius="2.4"
                    Background="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=HighlightBrush }"
                    Height="8"
                    VerticalAlignment="Top"
                    Opacity="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=Ratio, Converter={StaticResource SilverlightThemeRatioToOpacityConverter}, ConverterParameter=0}" />
         </Grid>
      </Border>
   </ControlTemplate>

   <!--**************************
    * STYLE: LoadingIndicator
    ************************** -->
   <Style x:Key="SilverlightThemeLoadingIndicatorStyle"
          TargetType="sllb:LoadingIndicator">
      <Setter Property="FadeOutAnimationDuration"
              Value="850" />
      <Setter Property="AnimationDuration"
              Value="1000" />
      <Setter Property="VerticalContentAlignment"
              Value="Bottom" />
      <Setter Property="HorizontalContentAlignment"
              Value="Right" />
      <Setter Property="IsHitTestVisible"
              Value="False" />
      <Setter Property="Template"
              Value="{StaticResource SilverlightThemeLoadingIndicatorTemplate}" />
   </Style>

   <!--**************************
    * STYLE: LoadingSpinner
    ************************** -->
   <Style x:Key="SilverlightThemeLoadingSpinnerStyle"
          TargetType="sllb:LoadingSpinner">
      <Setter Property="Margin"
              Value="10" />
      <Setter Property="HighlightBrush"
              Value="{StaticResource SilverlightThemeLoadingSpinnerHighlightBackgroundBrush}" />
      <Setter Property="ShadowBrush"
              Value="{StaticResource SilverlightThemeLoadingSpinnerShadowBackgroundBrush}" />
      <Setter Property="Template"
              Value="{StaticResource SilverlightThemeLoadingSpinnerTemplate}" />
   </Style>

   <!--**************************
    * STYLE: ListBox
    ************************** -->
   <Style x:Key="SilverlightThemeListBoxStyle"
          TargetType="sllb:ListBox">

      <Setter Property="BorderThickness"
              Value="1" />

      <Setter Property="BorderBrush"
              Value="{StaticResource SilverlightThemeListBoxDefaultBorderBrush}" />

      <Setter Property="Background"
              Value="White" />

      <Setter Property="Foreground"
              Value="Black" />

      <Setter Property="Padding"
              Value="1" />

      <Setter Property="IsTabStop"
              Value="False" />

      <Setter Property="Template"
              Value="{StaticResource SilverlightThemeListBoxTemplate}" />
   </Style>

   <!--**************************
    * STYLE: ListBoxItem
    ************************** -->
   <Style x:Key="SilverlightThemeListBoxItemStyle"
          TargetType="sllb:ListBoxItem">

      <Setter Property="Padding"
              Value="3" />

      <Setter Property="MinHeight"
              Value="24" />

      <Setter Property="HorizontalContentAlignment"
              Value="Stretch" />

      <Setter Property="VerticalContentAlignment"
              Value="Stretch" />

      <Setter Property="Background"
              Value="Transparent" />

      <Setter Property="BorderThickness"
              Value="0" />

      <Setter Property="BorderBrush"
              Value="Transparent" />

      <Setter Property="TabNavigation"
              Value="Local" />

      <Setter Property="Template"
              Value="{StaticResource SilverlightThemeListBoxItemTemplate}" />
   </Style>

   <!--**************************
    * STYLE: ListBoxGroupHeader
    ************************** -->
   <Style x:Key="SilverlightThemeListBoxGroupHeaderStyle"
          TargetType="sllb:ListBoxGroupHeader">
      <Setter Property="Background"
              Value="{StaticResource SilverlightThemeListBoxGroupHearderItemBackgroundBrush}" />

      <Setter Property="BorderThickness"
              Value="1" />

      <Setter Property="BorderBrush"
              Value="#C9CACA" />

      <Setter Property="Foreground"
              Value="#7691B4" />

      <Setter Property="Padding"
              Value="5,0,0,0" />

      <Setter Property="MinHeight"
              Value="34" />

      <Setter Property="HorizontalContentAlignment"
              Value="Stretch" />

      <Setter Property="VerticalContentAlignment"
              Value="Center" />

      <Setter Property="Template"
              Value="{StaticResource SilverlightThemeListBoxGroupHeaderTemplate}" />
   </Style>

   <!--**************************
    * STYLE: HierarchicalGroupPersenterItem
    ************************** -->
   <Style x:Key="SilverlightThemeHierarchicalGroupValueItem"
          TargetType="sllb:HierarchicalGroupValueItem">

      <Setter Property="IsTabStop"
              Value="False" />

      <Setter Property="HorizontalContentAlignment"
              Value="Left" />

      <Setter Property="VerticalContentAlignment"
              Value="Bottom" />

      <Setter Property="Template"
              Value="{StaticResource SilverlightThemeHierarchicalGroupValueItemTemplate}" />

   </Style>

   <!--**************************
    * STYLE: ListBox
    ************************** -->
   <Style TargetType="sllb:ListBox"
          BasedOn="{StaticResource SilverlightThemeListBoxStyle}" />

   <!--**************************
    * STYLE: ListBoxItem
    ************************** -->
   <Style TargetType="sllb:ListBoxItem"
          BasedOn="{StaticResource SilverlightThemeListBoxItemStyle}" />

   <!--**************************
    * STYLE: ListBoxGroupHeader
    ************************** -->
   <Style TargetType="sllb:ListBoxGroupHeader"
          BasedOn="{StaticResource SilverlightThemeListBoxGroupHeaderStyle}" />

   <!--**************************
    * STYLE: HierarchicalGroupValueItem
    ************************** -->
   <Style TargetType="sllb:HierarchicalGroupValueItem"
          BasedOn="{StaticResource SilverlightThemeHierarchicalGroupValueItem}" />

   <!--**************************
    * STYLE: LoadingIndicator
    ************************** -->
   <Style TargetType="sllb:LoadingIndicator"
          BasedOn="{StaticResource SilverlightThemeLoadingIndicatorStyle}" />

   <!--**************************
    * STYLE: LoadingSpinner
    ************************** -->
   <Style TargetType="sllb:LoadingSpinner"
          BasedOn="{StaticResource SilverlightThemeLoadingSpinnerStyle}" />

</ResourceDictionary>
